* This file sets parameters for the analysis of ptv restricted forecasts with evaluation.do
clear
local s="$c$freq"
import excel using ptvforecasts.xlsx, firstrow clear sheet("`s'")


*Parameters for portfolio allocation
global gamma=3
global minall=0
global maxall=1.5


*Load data and set periods
if $freq==4{
	global samplestart=19471
	global firstpred=19651
	global lastpred=20224
	global end1=20224-($h-1)
	global end2=19934
	global start2=19941
}
if $freq==12{
	global samplestart=194701
	global firstpred=196501
	global lastpred=202212
	global end1=202212-($h-1)
	global end2=199312
	global start2=199401
}


gen time=_n
tsset time

sum time if yy==$samplestart
global tsamplestart=r(mean)
sum time if yy==$firstpred
global tfirstpred=r(mean)
sum time if yy==$lastpred
global tlastpred=r(mean)
sum time if yy==$end1
global tend1=r(mean)
sum time if yy==$end2
global tend2=r(mean)
sum time if yy==$start2
global tstart2=r(mean)


